import request from "./request";

// 注册
export const Register = (params) => request.post('/open/register', params)

// 登录
export const Login = (params) => request.post('/login', params)


// 全部订单
export const GetallOrdersData = (params) => request.get("/order/v1/list", { params })

// 待发货
export const GetwaitGoodsData = (params) => request.get("/order/v1/list/1", { params })

// 待收货
export const GetReceiveGoodsData = (params) => request.get("/order/v1/list/2", { params })

// 待评价
export const GetWhitEvaluateData = (params) => request.get("/order/v1/list/3", { params })

// 发货
export const deliverGoods = (params) => request.post('/order/v1/send', params)

// 确认收货
export const affirmGoods = (serialNo) => request.post(`/order/v1/confirmReceipt/${serialNo}`)


// 订单详情
export const TheOrderDetails = (serialNo) => request.get(`/order/v1/orderInfo/${serialNo}`)


// 订单评价
export const OrderToEvaluate = (params) => request.post('/order/v1/evaluate', params)


// 评价详情
export const GetEvaluationDetails = (serialNo) => request.get(`/order/v1/evaluateInfo/${serialNo}`)

// 消息中心列表
export const GetInformationList = (params) => request.get('/api/message', { params })

// 标记信息为已读
export const GetReads = (params) => request.put(`/api/message/updates?id=${params}`)

// 消息中心详情
export const GetParticularsInformation = (id) => request.get(`/api/message/${id}`)

// 个人中心用户信息展示
export const GetUserInfo = () => request.get("/users/list")

// 个人中心用户信息详情
export const GetUserInfoDetails = () => request.get("/users/info")

// 个人中心 版本信息
export const GetUserVersions = () => request.get("/users/version")

//物流单列表
export const GetLogisticsSingleList = (params) => request.get('/api/star', { params })

// 物流单评论提交
export const CommentSubmit = (params) => request.put(`/api/star`, params)

// 查看物流单评论
export const ExamineLogisticsBillComment = (id) => request.get(`/api/star/${id}`)

// 客户列表信息
export const GetClientList = (params) => request.get('/api/cust', { params })

// 客户管理 客户信息
export const GetCustomerInformation = (id) => request.post(`/api/cust/${id}`)

// 客户信息详情
export const CustomerInformationDetails = (id) => request.get(`api/cust/${id}`)

// 修改客户信息
export const ModifyCustomerInformation = (params) => request.put(`/api/cust`, params)

// 新增客户
export const NewCustomer = (params) => request.post('/api/cust', params)

// 客户关怀
export const CustomerCare = (params) => request.get('/api/visit', { params })

// 新增走访
export const TheNewVisit = (params) => request.post('/api/visit', params)

// 走访信息详情
export const GetVisitDetails = (id) => request.get(`api/visit/${id}`)

